using System.Collections;
using System.Collections.Generic;
using ServerTools;
using UnityEditor;
using UnityEngine;


// [CustomEditor(typeof(Draw))]
public class Draw : Editor
{
    // Start is called before the first frame update

    // Update is called once per frame
    void OnSceneGUI()
    {
        
        if (ServerPath.getInstance().listDraw.Count <=0) return; 
        Handles.color = Color.yellow;
        Debug.Log("11111111111");
        for (int i = 0; i < ServerPath.getInstance().listDraw.Count; ++i)
        {
            Handles.DrawLine(ServerPath.getInstance().listDraw[i].A, ServerPath.getInstance().listDraw[i].B);
            Handles.DrawLine(ServerPath.getInstance().listDraw[i].A, ServerPath.getInstance().listDraw[i].C);
            Handles.DrawLine(ServerPath.getInstance().listDraw[i].C, ServerPath.getInstance().listDraw[i].B);
        }
        // Handles.DrawLine(ServerPath.getInstance().listDraw[0].A, ServerPath.getInstance().listDraw[0].B);
        // Handles.DrawLine(ServerPath.getInstance().listDraw[0].A, ServerPath.getInstance().listDraw[0].C);
        // Handles.DrawLine(ServerPath.getInstance().listDraw[0].C, ServerPath.getInstance().listDraw[0].B);
    }
}
